<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <title>Document</title>
</head>

<body>

</body>
<script type="text/javascript">
    // 判断一个整数是偶数还是奇数，并输出判断结果
    var num = +prompt("请输入一个整数：");
    if (num % 2 === 0) {
        console.log("偶数");
    } else {
        console.log("奇数");
    }
</script>

</html>